<?php
namespace Summer\Hjd\Http\Requests;

use Summer\Hub\Http\Requests\Request;
use Input;

class RgRecordCreateRequest extends Request
{
    /**
     * {@inheritDoc}
     */
    public function data()
    {
        $data = Input::all();
        return $data;
    }
    /**
     * Get the validation rules that apply to the request.
     *
     * @return array
     */
    public function rules()
    {
        return [
            'currency_slug' => 'required',
            'money' => 'required|numeric|positive',
            'pay_type' => 'required',
        ];
    }
    public function messages()
    {
        return [
            'currency_slug.required'    => '请选择充值币种.',
            'money.required'    => '充值金额不能为空.',
            'money.numeric'    => '充值金额必须为数字.',
            'money.positive'    => '充值金额必须为正数.',
            'pay_type.required'    => '请选择充值支付方式.',
        ];
    }
}
